package com.doudou.zuul.config;


import com.doudou.zuul.entity.AppAccess;
import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

import java.util.List;
import java.util.Set;
import java.util.concurrent.CopyOnWriteArrayList;
import java.util.concurrent.CopyOnWriteArraySet;

@Component
@ConfigurationProperties(prefix = "app")
@Data
public class AppConfig {

    public  String localAppName;

    private boolean enableLocalLogPrefix;

    private String localRefreshTokenPoint;

    private String remoteRefreshTokenPoint;

    private String remoteCheckTokenPoint;

    private String logoutUrl;

    /**
     * 登录数据提交白名单
     */
    private Set<String> loginDataUrls = new CopyOnWriteArraySet();


    /**
     * 不同应用的授权数据
     */
    private List<AppAccess> appAccesses = new CopyOnWriteArrayList<>();
}
